package com.ruoyi.finance.api;

import com.ruoyi.common.core.constant.SecurityConstants;
import com.ruoyi.common.core.constant.ServiceNameConstants;
import com.ruoyi.common.core.domain.R;
import com.ruoyi.finance.api.factory.RemoteBuyMustPayFallbackFactory;
import com.ruoyi.finance.domain.BuyMustPay;
import com.ruoyi.system.api.factory.RemoteFileFallbackFactory;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestHeader;


@FeignClient(contextId = "remoteBuyMustPayService", value = ServiceNameConstants.FINANCE_SERVICE, fallbackFactory = RemoteBuyMustPayFallbackFactory.class)
public interface RemoteBuyMustPayService {

    @PostMapping("/buyMustPay/innerAdd")
    public R<Boolean> addBuyMustPay(@RequestBody BuyMustPay buyMustPay, @RequestHeader(SecurityConstants.FROM_SOURCE) String source);
}
